import { request } from "../utils/request";

async function getById(params) {
    const result = await request({
        url: `/user/get/${params}`,
        method: 'GET',
        // params: params
    })
    return result;
}

async function getAll() {
    const result = await request({
        url: '/user/getAll',
        method: 'GET'
    })
    return result;
}

async function saveOrUpdate(data) {
    const result = await request({
        url: "/user/saveOrUpdate",
        method: "POST",
        data: data
    });
    return result;
}

export { getById, getAll, saveOrUpdate }